package com.whpu.mall.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.whpu.common.utils.PageUtils;
import com.whpu.mall.product.entity.BrandEntity;
import com.whpu.mall.product.entity.CategoryBrandRelationEntity;

import java.util.List;
import java.util.Map;

/**
 * 品牌分类关联
 *
 * @author FanboKai
 * @email fanbokai163@163.com
 * @date 2021-02-05 09:37:23
 */
public interface CategoryBrandRelationService extends IService<CategoryBrandRelationEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void saveDetail(CategoryBrandRelationEntity categoryBrandRelation);

    //同步更新其他关联表中的数据,根据id更改name
    void updateBrand(Long brandId, String name);

    //级联更新分类所有关联数据
    void updateCategory(Long catId, String name);

    //根据分类id查对应关联品牌
    List<BrandEntity> getBrandListByCatId(Long catId);
}

